﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Model;
using DAL;

namespace BLL
{
    public class UrlRouteBLL : BaseBLL
    {
        #region 构造函数

        public UrlRouteBLL(LoginInfo info)
        {
            loginInfo = info;
        }
        #endregion

        #region 公共函数

        public UrlRoute GetInfoById(string id)
        {
            UrlRouteDAL funDal = new UrlRouteDAL(loginInfo);
            var result = funDal.GetInfoById(id);
            return result;
        }

        public List<UrlRoute> GetList( out int recordCount)
        {
            UrlRouteDAL funDal = new UrlRouteDAL(loginInfo);
            var result = funDal.GetList(out  recordCount);
            return result;
        }

        public int Insert(UrlRoute urlRoute)
        {
            UrlRouteDAL funDal = new UrlRouteDAL(loginInfo);
            var result = funDal.Insert(urlRoute);
            return result;
        }

        public int Update(UrlRoute urlRoute)
        {
            UrlRouteDAL funDal = new UrlRouteDAL(loginInfo);
            var result = funDal.Update(urlRoute);
            return result;
        }

        public int Delete(string id)
        {
            UrlRouteDAL funDal = new UrlRouteDAL(loginInfo);
            var result = funDal.Delete(id);
            return result;
        }
        #endregion
    }
}
